#!/bin/bash
set -euo pipefail

rm -rf build
mkdir build

cd src
zip -r ../build/zotcard-3.3.0.xpi *
cd ../build

jq ".addons[\"zotcard@zotero.org\"].updates[0].update_hash = \"sha256:`shasum -a 256 zotcard-3.3.0.xpi | cut -d' ' -f1`\"" ../updates.json.tmpl > ../updates.json
